package com.homework.work01;

public class TypeConversionDemo {
    public static void main(String[] args) {
        //自动转换
        byte a = 1;
        long b = a;
        System.out.println(b);
        // 'a' 和97的底层unicode码一样所以‘a’自动转为97
        char c = 'a';
        int d = c;
        System.out.println(d);
        //强制转换(注意越界问题)
        int e = 128;
        byte j = (byte)e;
        System.out.println(j);
    }
}
